{% include "../../header.html" %}
{% include "../../navigation.html" %}

<div class="wrapper">
    <div class="container-fluid">

        <!-- Page-Title -->
        <div class="row">
            <div class="col-sm-12">
                <div class="page-title-box">
                    <div class="btn-group pull-right">
                        <h4 class="page-title">Forum List</h4>
                    </div>
                    <ol class="breadcrumb hide-phone p-0 m-0">
                        <li class="breadcrumb-item"><a href="#">HuntCMS</a></li>
                        <li class="breadcrumb-item"><a href="#">Forum</a></li>
                        <li class="breadcrumb-item active">Forum List</li>
                    </ol>
                </div>
            </div>
        </div>
        <!-- end page title end breadcrumb -->




        <div class="row">
            <div class="col-12">
                <div class="card-box">
                    <div class="row">
                        <div class="col-sm-6">
                            <div class="m-b-30">
                                <a href="{{ url('forum.forum.add', '')}}" id="addToTable" class="btn btn-success waves-effect waves-light">Add <i class="mdi mdi-plus-circle-outline"></i></a>
                            </div>
                        </div>
                    </div>

                    <table class="table table-striped add-edit-table" id="datatable-editable">
                        <thead>
                        <tr>
                            <th data-toggle="true">Name</th>
                            <th data-hide="phone">Icon</th>
                            <th data-hide="phone, tablet">Subnode</th> 
                            <th data-hide="phone, tablet">Status</th>
                            <th data-hide="phone, tablet">Operate</th>
                            
                        </tr>
                        </thead>

                        <div class="form-inline m-b-20">
                            <div class="row">
                                <div class="col-md-12 text-xs-center">
                                    <form class="form-horizontal" role="form" action="" method="get">
                                        <div class="form-group float-left m-r-5">
                                            <input id="demo-foo-search" name="k" type="text" placeholder="Search Forum" class="form-control" 
                                            autocomplete="on">
                                        </div>
                        
                                        <div class="form-group float-left m-r-5">
                                            <button type="submit"
                                                    class="btn btn-icon waves-effect waves-light btn-success m-b-5"><i
                                                    class="fa fa-search"></i></button>
                                        </div>
                                        <div class="form-group float-left m-r-5">
                                            <a href="{{ url('forum.forum.list' , '')}}"
                                                class="btn btn-icon waves-effect waves-light btn-success m-b-5"><i
                                                    class="fa fa-refresh"></i></a>
                                        </div>
                                    </form>
                                </div>
                               
                            </div>
                        </div>
                        
                        <tbody>
                            {% for forum in forums %}
                                <tr>
                                   
                                    <td><a href="{{ url('forum.forum.edit', '')}}?id={{ forum.id }}">{{ forum.name }}</a></td>
                                    <td>{% if forum.icon %}<img style="height:40px;" src="{{ forum.icon }}">{% endif %}</td>
                                    <td><a href="{{ url('forum.forum.list1','')}}?id={{ forum.id }}">Subnode</a></td>
                                    <td><span class="badge label-table badge-success">
                                        {% if forum.status == 0 %}
                                            Disabled
                                        {% elif forum.status == 1 %}
                                            Active
                                        {% else %}
                                            Suspended
                                        {% endif %}
                                    </span></td>
                                    <td class="actions">
                                        <a href="{{ url('forum.forum.del', '')}}?id={{ forum.id }}" class="on-default remove-row" data-toggle="tooltip" data-placement="top" title="" data-original-title="Click Delete"><i class="fa fa-trash-o"></i></a>
                                        
                                    </td>
                                </tr>
                            {% endfor %}
                        </tbody>
                        <tfoot>
                        <tr class="active">
                            <td colspan="5">
                                <div class="text-right">
                                    <ul class="pagination pagination-split justify-content-end footable-pagination m-t-10 m-b-0"></ul>
                                </div>
                            </td>
                        </tr>
                        </tfoot>
                    </table>
                </div>
            </div>
        </div>

        <div class="clearfix">
            {% include "../../paginate.html" %}
        </div>
        <!-- end row -->

    </div> <!-- end container -->
</div>
<!-- end wrapper -->

{% include "../../footer.html" %}
